home *** CD-ROM | disk | FTP | other *** search
/ Gold Medal Software 3 / Gold Medal Software - Volume 3 (Gold Medal) (1994).iso / database / movies27.arj / INSTALL.FIL < prev    next >
Text File  |  1994-04-03  |  10KB  |  386 lines

  1. ' MOVIES TO GO!  DOS / WINDOWS Installation Script
  2. ' Copyright 1993, ImagiSOFT, Inc.
  3. ' Version 2.7
  4. ' April 3, 1994
  5.  
  6. ' Note:  This installation script is written for THE FINISHING TOUCH, a
  7. '        professional installation program which is also an ImagiSOFT
  8. '        product.  It is distributed with MOVIES TO GO! to make
  9. '        installation easier, and to reduce our support calls.
  10.  
  11. '        This script unpacks 6 compressed files (*.PAK) which is a
  12. '        major feature of the program.  For more information about
  13. '        THE FINISHING TOUCH, call ImagiSOFT at (505) 275-1920, or call
  14. '        our personal BBS number at (505) 275-9697.
  15. '        It will always have the latest shareware version of
  16. '        THE FINISHING TOUCH so you can "try before you buy".
  17.  
  18. BACKGROUND ~0\INSTALL.BIN ' load binary file background
  19. TELESCOPE OFF
  20.  
  21. LANGUAGE ENGLISH       ' may be changed to GERMAN, FRENCH, SPANISH, DANISH, or DUTCH
  22.  
  23. TELESCOPE ON
  24. SHADOW OFF
  25. SPACE 1500              ' if they don't have 1.5 meg free, forget it
  26. PAUSE 300               ' wait 3 seconds
  27.  
  28. ' display opening menu
  29. :OPENING
  30.  
  31. WINOPEN 0 8 31
  32. "        INSTALLATION OPTIONS MENU"
  33. ""
  34. "1.  Install as Microsoft Windows 3.1 Application"
  35. "2.  Install as DOS Application"
  36. "3.  QUIT"
  37. ""
  38. "SELECT ONE OF THE ABOVE:    "
  39.  
  40. WINUPDATE +10 +1 30
  41. "INSTALLATION OPTIONS MENU"
  42. INPUT A 1 +28 +7 15
  43. WINCLOSE
  44.  
  45. CALL TEMP_FILE                 ' create temporary file
  46.  
  47. EXIST ~3\1.TMP                 ' selected windows install
  48. JUMP.YES WINDOWS_APP
  49.  
  50. EXIST ~3\2.TMP                 ' selected dos install
  51. JUMP.YES DOS_APP
  52.  
  53. EXIST ~3\3.TMP                 ' exit
  54. JUMP.YES EXIT
  55.  
  56. BEEP
  57. CALL TMP_DEL                   ' delete temporary file
  58. JUMP OPENING
  59.  
  60. ' ------------------------
  61. '   install as a dos app
  62. ' ------------------------
  63. :DOS_APP
  64. CALL TMP_DEL                   ' delete temporary file
  65.  
  66. ' have user set the drive
  67. CALL ESC
  68. DRIVE C 0 12 31 15 32 14 79
  69. WINCLOSE
  70.  
  71. ' have user set the path
  72. CALL ESC
  73. PATH \MOVIES 0 12 31 15 32 14 79
  74. WINCLOSE
  75.  
  76. CALL EMPTY_DIR                        ' make sure directory is empty
  77. CALL UNPACK                           ' unpack data files
  78.  
  79. ' create movies batch file
  80. PROMPT OFF
  81. DELETE ~1\MOVIES.BAT 1 24 51
  82. PROMPT ON
  83. FILE ~1\MOVIES.BAT
  84. "~1"
  85. "cd ~2"
  86. "MOVIES"
  87. "cd \"
  88.  
  89. CALL PRINT         ' print the documentation y/n?
  90.  
  91. WINOPEN 0 8 31
  92. "MOVIES TO GO! has been successfully installed."
  93. ""
  94. "     To run it, enter the command"
  95. "     from the root directory of drive ~1."
  96. ""
  97. ""
  98. ""
  99. ""
  100. "Press the [Enter] key to continue."
  101. WINUPDATE +36 +3 30
  102. "MOVIES"
  103. WINUPDATE +7 +6 27
  104. "THANK YOU FOR CHOOSING OUR SOFTWARE!"
  105. WAIT +36 +9
  106. WINCLOSE
  107.  
  108. :RUN
  109. WINOPEN 0 11 31
  110. "Would you like to run MOVIES TO GO! right now   Y or N?"
  111. ASK +57 +1
  112. JUMP.NO EXIT
  113. RUN ~1\MOVIES.BAT
  114.  
  115. ' --------------------------
  116. '   install as windows app
  117. ' --------------------------
  118. :WINDOWS_APP
  119.  
  120. ' these commands set drive and path variables
  121. DRIVE C                        ' set ~1 to drive c
  122. PATH \WINDOWS                  ' set ~2 path
  123.  
  124. :TEST_WIN
  125. EXIST ~1~2\WIN.COM             ' check for windows
  126. JUMP.YES WIN_INSTALL
  127.  
  128. PROMPT OFF
  129. RD C:\WINDOWS                  ' the above exist command created this empty directory.  if it is legitimate, this command will fail, causing no harm
  130. PROMPT ON
  131.  
  132. EXIST ~3\1.TMP                 ' 1st time through, ignore beep
  133. JUMP.YES SKIP_BEEP
  134. BEEP
  135. RD ~1~2                        ' remove newly created, empty directory
  136. WINOPEN 0 8 79
  137. "Microsoft Windows is NOT found in the"
  138. "~1~2 directory.  Please try again."
  139. ""
  140. "Press ENTER to continue."
  141. WAIT +26 +4
  142. WINCLOSE
  143.  
  144. ' windows is in a directory other than C:\WINDOWS
  145. :SKIP_BEEP
  146. CALL TMP_DEL                   ' delete temporary file
  147. WINOPEN 0 8 31
  148. "To install MOVIES TO GO! to Microsoft Windows,"
  149. "we need to know which hard drive Windows is installed on."
  150. ""
  151. "             Most people have Windows on this hard drive."
  152. "             Press ENTER if this is correct, or change to"
  153. "             the correct drive letter."
  154. "             (Press ESC to quit.)"
  155. PROMPT OFF
  156. DRIVE C +2 +3 17 14 32 14 79
  157. WINCLOSE
  158.  
  159. PROMPT ON
  160. WINOPEN 0 8 31
  161. "We also need to know the name of the directory where Microsoft"
  162. "Windows is installed.  Most people have Windows installed in"
  163. "                              this directory.  Press ENTER"
  164. "                              if this is OK, or input the name"
  165. "                              of the directory where Windows"
  166. "                              is installed."
  167. "                              (Press ESC to quit.)"
  168. PROMPT OFF
  169. PATH \WINDOWS +1 +3 17 14 32 14 79
  170. WINCLOSE
  171. PROMPT ON
  172. PROMPT OFF
  173. JUMP TEST_WIN                       ' loop until valid input or quit
  174.  
  175. ' you know the windows directory, now install it
  176. :WIN_INSTALL
  177. CALL TMP_DEL                        ' delete temporary file
  178.  
  179. FILE ~1~2\PROGMAN.INI               ' edit program manager file - add group #504 (arbritary high number)
  180. "Group504=~1\MOVIES\MOVIES.GRP"
  181.  
  182. PATH \MOVIES                        ' set ~2 path (windows group / pif file forces the directory name)
  183. MD ~1~2                             ' make the directory
  184. CALL EMPTY_DIR                      ' make sure directory is empty
  185.  
  186. WINOPEN 0 20 79
  187. "MOVIES TO GO! is being installed to the ~1~2 directory . . ."
  188.  
  189. CALL UNPACK                         ' unpack data files
  190. UNPACK WINDOWS.PAK 0 10 31 32 15 79 ' windows pif, ico, and grp files
  191. JUMP.FAIL INSTALL_FAILURE
  192.  
  193. COPY ~0~\VIEW.COM ~1~2\ 0 0 0         ' copy file viewer
  194.  
  195. WINCLOSE                            ' closes winopen above
  196.  
  197. CALL PRINT                          ' print docs y/n?
  198.  
  199. ' --------------------------------
  200. '  successful install to windows
  201. ' --------------------------------
  202. WINOPEN 0 8 31
  203. "MOVIES TO GO! has been successfully installed in your"
  204. "Windows environment.  However, the changes won't take"
  205. "effect until you exit Windows, then run Windows again."
  206. ""
  207. ""
  208. ""
  209. "Press ENTER to return to Windows."
  210. WINUPDATE +5 +5 27
  211. "THANK YOU FOR CHOOSING OUR SOFTWARE!"
  212. WAIT +35 +7
  213. WINCLOSE
  214. END
  215.  
  216. ' ------------------
  217. '   error messages
  218. ' ------------------
  219. :INSTALL_FAILURE
  220. WINOPEN 0 8 79
  221. "MOVIES TO GO! INSTALLATION FAILED BEFORE IT FINISHED!!"
  222. ""
  223. "Possible reasons:"
  224. "   -- The floppy disk was damaged during shipping."
  225. "   -- Your disk drive is out of alignment."
  226. "   -- The floppy disk was removed prior to completion."
  227. ""
  228. "Press [Enter] to Continue."
  229. WAIT +28 +8
  230. WINCLOSE
  231. JUMP EXIT
  232.  
  233. ' -----------
  234. ' subroutines
  235. ' -----------
  236. :EMPTY_DIR
  237. EXIST ~1~2\*.*                       ' check to see if directory is empty
  238. JUMP.NO SKIP_SURE
  239.  
  240. EXIST ~1~2\1*.FIL                     ' if it is previous MOVIES TO GO! OK
  241. JUMP.YES SKIP_SURE
  242.  
  243. WINOPEN 0 8 79
  244. "The directory ~1~2 already exists and contains files!"
  245. ""
  246. "   Installing MOVIES TO GO! in this directory will"
  247. "                DELETE ALL THE FILES"
  248. "       in this directory prior to installing."
  249. ""
  250. ""
  251. WINUPDATE +2 +7 78
  252. "Are you SURE you want to install it here   Y or N?"
  253. ASK +52 +7
  254. WINCLOSE
  255. JUMP.YES SKIP_SURE
  256. JUMP DOS_APP
  257.  
  258. :SKIP_SURE
  259. PROMPT OFF                            ' don't show files being deleted
  260. COPY ~1~2\NOTE.FIL ~1\NOTE.FIL 0 0 0  ' preserve users personal notes
  261. DELETE ~1~2\*.* 1 24 51               ' delete all files in case they are
  262. PROMPT ON                             ' installing a 2nd time
  263. CALL TMP_DEL                          ' delete temporary file
  264. RETURN
  265.  
  266. '   delete temporary file (don't inform user)
  267. :TMP_DEL
  268. PROMPT OFF
  269. DELETE ~3\~A.TMP 0 0 0
  270. PROMPT ON
  271. RETURN
  272.  
  273. ' unpack data files
  274. :UNPACK
  275. SET.FILES 16                          ' make sure files >=16 in autoexec.bat
  276. UNPACK DATA.PAK 0 10 31 32 15 79      ' data files
  277. JUMP.FAIL INSTALL_FAILURE
  278.  
  279. UNPACK TEXT.PAK 0 10 31 32 15 79      ' text version, other necessary files
  280. JUMP.FAIL INSTALL_FAILURE
  281.  
  282. VIDEO VGA                              ' test for VGA or better
  283. JUMP.NO NO_VGA                         ' to see whether to install graphics
  284.  
  285. :GRAPHICS_INSTALL
  286. EXIST ~0\GRAPHICS.PAK                  ' prompt for 2nd disk on 720 k setup
  287. JUMP.YES HD_DISK
  288.  
  289. WINOPEN 0 10 31
  290. BEEP
  291. "Please Insert Disk Number 2 in Drive ~0."
  292. ""
  293. "Press the [Enter] key to continue."
  294. WAIT +36 +3
  295. WINCLOSE
  296. JUMP GRAPHICS_INSTALL                  ' loop until correct disk inserted
  297.  
  298. :HD_DISK
  299. CPU 386                                ' look for 386+
  300. JUMP.YES 386
  301.  
  302. WINOPEN 0 10 31
  303. "The GRAPHICS VERSION May Be Slow on Your Computer."
  304. ""
  305. ""
  306. ""
  307. "(If you decide that the graphics version is too slow, simply"
  308. " install the software again, and answer  N  to this question.)"
  309. WINUPDATE +2 +3 30
  310. "Do You Want To Install it Anyway   Y or N?"
  311. ASK +44 +3
  312. WINCLOSE
  313. JUMP.NO NO_VGA
  314.  
  315. :386
  316. FREE 1200                                ' disk space for graphics version
  317. JUMP.NO NO_VGA
  318. UNPACK GRAPHICS.PAK 0 10 31 32 15 79     ' graphics version
  319. JUMP.FAIL INSTALL_FAILURE
  320.  
  321. COPY ~1\NOTE.FIL ~1~2\NOTE.FIL 0 0 0     ' copy client's personal notes file back
  322.  
  323. FREE 1000                                ' disk space for animated icons
  324. JUMP.NO DONE_PACK
  325. UNPACK ICON.PAK 0 10 31 32 15 79         ' fun stuff
  326. JUMP.FAIL INSTALL_FAILURE
  327. JUMP DONE_PACK
  328.  
  329. :NO_VGA                                     ' only text version
  330. PROMPT OFF
  331. COPY ~1~2\TEXT.EXE ~1~2\MOVIES.EXE 1 24 51  ' rename text program
  332. DELETE ~1~2\TEXT.EXE 1 24 51
  333. DELETE ~1~2\ICON.ML  1 24 51
  334. PROMPT ON
  335. :DONE_PACK
  336. RETURN
  337.  
  338. ' print the documentation y/n?
  339. :PRINT
  340. WINOPEN 0 10 30
  341. "Would you like to PRINT the 36 Page Manual   Y or N?"
  342. ASK +54 +1
  343. WINCLOSE
  344. JUMP.NO BYE_PRINT
  345.  
  346. WINOPEN 0 10 79
  347. ""
  348. "   Printing 36 Pages . . .  "
  349. ""
  350. PRINT ~1~2\MOVIES.TXT
  351. WINCLOSE
  352. JUMP.FAIL PRINTER_ERROR
  353. JUMP BYE_PRINT
  354.  
  355. :PRINTER_ERROR
  356. WINOPEN 0 10 79
  357. "Your Printer is not responding.  Possible problems:"
  358. ""
  359. "  -- Printer is not turned on"
  360. "  -- Printer is out of paper"
  361. "  -- Printer is not attached to LPT1 (parallel port 1)"
  362. ""
  363. ""
  364. WINUPDATE +2 +7 78
  365. "Do you want to try to print again  Y or N?"
  366. ASK +44 +7
  367. WINCLOSE
  368. JUMP.YES PRINT
  369. :BYE_PRINT
  370. RETURN
  371.  
  372. ' create a temporary file in the default directory with a unique name based on the number input by the user
  373. :TEMP_FILE
  374. FILE ~3\~A.TMP
  375. "Delete this temporary file."
  376. RETURN
  377.  
  378. :ESC
  379. WINOPEN 0 20 31
  380. "(Press ESC to Quit) "
  381. RETURN
  382.  
  383. :EXIT
  384. CALL TMP_DEL                   ' delete temporary file
  385. END
  386.